package com.cymal.model;

import lombok.Data;
import lombok.ToString;

import java.util.ArrayList;
import java.util.List;

/**
 * 对应一个Redis集群
 */
@Data
@ToString
public class RedisServer {
    private String name;
    private RedisNode master;
    private List<RedisNode> slaves = new ArrayList<>();

    public void addRedisNode(RedisNode redisNode) {
        slaves.add(redisNode);
    }
}
